#ifndef _CAP_LIB_H__
#define _CAP_LIB_H__
// Capture support for Library for 
// Streambox PVR codec..
// Disigned and tested for ATI All-in-Wonder Pro 128
// Created: July-09-2001
// alex@streambox.com

#include <windows.h>
#include "../Common/cTypes.h"
#include "common/capTypes.h"

#ifdef __cplusplus
extern "C" {
#endif

	// return 0 - AudioOnly device used
	// return 1 - Video device used
	int capPVR_GetDeviceMode();
	
	//------------------------------------ deprecated 
	// use capPVR_Create instead this !!!!
//	int capPRV_SetParent(void* /*HWND* */ Parent, int ID);
//	int capPVR_Init(int w,int h, int nFPS);
	//----------------------------------------------------

	int capPVR_Create(const CAPLIBCREATESTRUCT *pParam);

	int capPVR_Abort();
	int capPVR_Stop();
	int capPVR_Start();
	// Setup callback function ---------------------------
	void capPVR_SetCallback(CAP_PROCESS proc);
	BOOL capPVR_SetVideoSource();
	BOOL capPVR_SetAudioStatus(BOOL bAudioStatus);
	BOOL capPVR_SetVideoStatus(BOOL bVideoStatus);
	BOOL capPVR_SetFrameRate(int nFrameRate);
	void capPVR_grab();

	// compress image and process (for custom still images)
	void CompressStillImage(void* RGB, void ** dest, int *size);
    void SetStillImage(void* RGB,int Mbps);
    void SetCompressedStillImage(void* data,int size);

	extern int		QUALITY;
	extern int		FrameNum;
	extern int		capW;
	extern int		capH;
	extern char AUDIO_SILENSE[33];

#ifdef __cplusplus
}
#endif



#endif